﻿@using FL.SiteEntity;
@using FL.Common;
@using FL.Bussiness.Site;
@{
    var isLogin = (Session["User"] == null);
    string code = Model.code;
    string type = Model.type;
    t_site_ad ad = BArticle.CreateInstance().GetAd(code);
}
@if(ad!=null)
{
    switch (type)
    {
        case "pic":
            <a href="@ad.link_url" target="_blank"><img src="@ad.image_url" style="width:100%;height:150px;"/></a>
            break;
        case "text":
            <div style="border:1px solid #ccc;width:100%;margin-bottom:8px">
                @ad.ref_script
                <div>广告</div>
            </div>
            break;
       case "video":
            <a href="" target="_blank"></a>
            break;
        default:
            break;
    }

}